﻿
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[sproc_GetDimissionStaff]') AND type in (N'P', N'PC'))
    DROP PROCEDURE [dbo].[sproc_GetDimissionStaff];
GO
CREATE PROCEDURE [dbo].[sproc_GetDimissionStaff]
/*

============================================================
功能:    得到离职员工
参数:
    无
============================================================

*/

AS
SELECT a.*,b.Position_Name FROM uds_staff a,uds_Position b,uds_staff_in_position c
    WHERE c.Position_id = b.Position_id and dimission = 1 and a.staff_id = c.staff_id